import request from '@/utils/request'

// 获取个人中心活动列表
export function getProjectList(data) {
  return request({
    url: '/project/projectList',
    method: 'post',
    data: data
  })
}
// 新建活动
export function addProject(data) {
  return request({
    url: '/project/edit',
    method: 'post',
    data: data
  })
}

// 删除活动
export function delProject(data) {
  return request({
    url: '/project/del',
    method: 'post',
    data: data
  })
}

// 获取活动明细
export function getProjectInfo(query) {
  return request({
    url: '/project/info',
    method: 'get',
    params: query
  })
}


// 阶段列表
export function getStageList(data) {
  return request({
    url: '/project/stage/mission/list',
    method: 'post',
    data: data
  })
}

// 阶段列表-个人中心
export function getStageListPms(data) {
  return request({
    url: '/project/stage/mission/adminList',
    method: 'post',
    data: data
  })
}

// 新建阶段
export function addTask(data) {
  return request({
    url: '/project/stage/mission/edit',
    method: 'post',
    data: data
  })
}

// 删除阶段
export function delTask(data) {
  return request({
    url: '/project/stage/mission/del',
    method: 'post',
    data: data
  })
}

// 成果列表
export function getResultList(data) {
  return request({
    url: '/project/result/adminList',
    method: 'post',
    data: data
  })
}

// 成果推优
export function excellentSave(data) {
  return request({
    url: '/project/Excellent/save',
    method: 'post',
    data: data
  })
}

// 成果取消推优
export function excellentUpdate(data) {
  return request({
    url: '/project/Excellent/update',
    method: 'post',
    data: data
  })
}


// 优秀成果列表
export function getExcellentList(data) {
  return request({
    url: '/project/Excellent/list',
    method: 'post',
    data: data
  })
}

// 成果列表-普通用户
export function getResultListCommon(data) {
  return request({
    url: '/project/result/list',
    method: 'post',
    data: data
  })
}

// 资料列表
export function getInfomationList(data) {
  return request({
    url: '/project/file/list',
    method: 'post',
    data: data
  })
}

// 新增资料
export function addInformation(data) {
  return request({
    url: '/project/file/edit',
    method: 'post',
    data: data
  })
}

// 推送资料
export function syncEdit(data) {
  return request({
    url: '/material/syncEdit',
    method: 'post',
    data: data
  })
}

// 删除资料
export function delInformation(data) {
  return request({
    url: '/project/file/del',
    method: 'post',
    data: data
  })
}

// 删除成果
export function delResult(data) {
  return request({
    url: '/project/result/del',
    method: 'post',
    data: data
  })
}

// 审核列表
export function getAuditList(data) {
  return request({
    url: '/project/join/proUserList',
    method: 'post',
    data: data
  })
}

// 审核报名
export function updateAudit(data) {
  return request({
    url: '/project/join/update',
    method: 'post',
    data: data
  })
}

// 我的活动
export function getMyProjectList(data) {
  return request({
    url: '/project/projectForMy',
    method: 'post',
    data: data
  })
}

// 计划列表
export function getPlanList(data) {
  return request({
    url: '/project/plan/list',
    method: 'post',
    data: data
  })
}

// 新建计划
export function addPlan(data) {
  return request({
    url: '/project/plan/edit',
    method: 'post',
    data: data
  })
}

// 删除计划
export function delPlan(data) {
  return request({
    url: '/project/plan/del',
    method: 'post',
    data: data
  })
}


// 计划明细
export function getPlanInfo(query) {
  return request({
    url: '/project/plan/info',
    method: 'get',
    params: query
  })
}


// 修改计划状态
export function savePlanStatus(data) {
  return request({
    url: '/project/plan/saveStatus',
    method: 'post',
    data: data
  })
}

// 获取待选教师
export function getTeacherList(query) {
  return request({
    url: '/project/getProTeacher',
    method: 'get',
    params: query
  })
}

// 获取待选学生
export function getStudentList(query) {
  return request({
    url: '/project/getProUser',
    method: 'get',
    params: query
  })
}

// 导出成员
export function getProUserExcel(query) {
  return request({
    url: '/project/getProUserExcel',
    method: 'get',
    params: query,
    responseType: 'blob',
    headerRequired: true
  })
}

// 获取待选学生
export function getPmsMenu(query) {
  return request({
    url: '/backstage/getList',
    method: 'get',
    params: query
  })
}


// 通知列表
export function getNoticeList(data) {
  return request({
    url: '/project/announcement/list',
    method: 'post',
    data: data
  })
}

// 通知计划
export function addNotice(data) {
  return request({
    url: '/project/announcement/edit',
    method: 'post',
    data: data
  })
}

// 通知计划
export function delNotice(data) {
  return request({
    url: '/project/announcement/del',
    method: 'post',
    data: data
  })
}

// 计划明细
export function getNoticeInfo(query) {
  return request({
    url: '/project/announcement/info',
    method: 'get',
    params: query
  })
}

// 通知置顶
export function editForTop(data) {
  return request({
    url: '/project/announcement/editForTop',
    method: 'post',
    data: data
  })
}

// 修改答疑
export function addProblems(data) {
  return request({
    url: '/project/qa/addText',
    method: 'post',
    data: data
  })
}

// 获取答疑
export function getProblems(query) {
  return request({
    url: '/project/qa/list',
    method: 'get',
    params: query
  })
}

// 获取我的审核列表
export function getMyAuditList(data) {
  return request({
    url: '/project/join/selectList',
    method: 'post',
    data: data
  })
}

// 提交审核
export function submitAudit(data) {
  return request({
    url: '/project/join/proVisible',
    method: 'post',
    data: data
  })
}

// 审核操作
export function handleAudit(data) {
  return request({
    url: '/project/join/proReview',
    method: 'post',
    data: data
  })
}


// 审核详情
export function getAuditInfo(query) {
  return request({
    url: '/project/join/proReviewInfo',
    method: 'get',
    params: query
  })
}

// 审核详情-活动管理
export function getAuditProInfo(query) {
  return request({
    url: '/project/join/proInfo',
    method: 'get',
    params: query
  })
}

// 报名详情
export function getJoinInfo(query) {
  return request({
    url: '/project/join/proUserInfo',
    method: 'get',
    params: query
  })
}

// 获取我的提交列表
export function getMyApplication(data) {
  return request({
    url: '/project/join/mySubmission',
    method: 'post',
    data: data
  })
}

// 知识中心列表
export function getKnowledgeList(data) {
  return request({
    url: '/project/file/myList',
    method: 'post',
    data: data
  })
}

// 新增知识
export function addKnowledge(data) {
  return request({
    url: '/project/file/myEdit',
    method: 'post',
    data: data
  })
}

// 删除知识
export function delKnowledge(data) {
  return request({
    url: '/project/file/myDel',
    method: 'post',
    data: data
  })
}

// 从知识中心批量导入资料
export function addInformationFromKnowledge(data) {
  return request({
    url: '/project/file/editList',
    method: 'post',
    data: data
  })
}

//评价列表
export function getEvaluateList(data) {
  return request({
    url: '/evaluate/list',
    method: 'post',
    data: data
  })
}

// 评价详情第一层
export function getEvaluateInfo(query) {
  return request({
    url: '/evaluate/projectInfo',
    method: 'get',
    params: query
  })
}

// 评价详情第二层
export function getStageInfo(query) {
  return request({
    url: '/evaluate/stageInfo',
    method: 'get',
    params: query
  })
}

// 评价下载文件
export function getEvaluateZip(query) {
  return request({
    url: '/evaluate/evaluateZip',
    method: 'get',
    params: query,
    responseType: 'blob',
    headerRequired: true
  })
}

// 提交评价
export function saveEvaluate(data) {
  return request({
    url: '/evaluate/save',
    method: 'post',
    data: data
  })
}

// 修改图谱首页
export function saveSpectrum(data) {
  return request({
    url: '/spectrum/edit',
    method: 'post',
    data: data
  })
}

//图谱-首页表-获取列表详情
export function getSpectrumListInfo(query) {
  return request({
    url: '/spectrum/info',
    method: 'get',
    params: query
  })
}

//图谱-首页表-获取单条详情
export function getSpectrumInfo(query) {
  return request({
    url: '/spectrum/getInfo',
    method: 'get',
    params: query
  })
}

